package com.czxy.enterprise.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.czxy.domain.TbRecruitmentInfo;
import com.czxy.vo.CityVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 * 招聘信息表 Mapper 接口
 * </p>
 *
 * @author xuewen
 * @since 2022-01-25
 */
@Mapper
public interface RecruitmentInfoMapper extends BaseMapper<TbRecruitmentInfo> {

    @Select("select count(*) num,tc.city_name from tb_city tc, tb_recruitment_info tr where tc.city_id = tr.address_id group by\n" +
            " tr.address_id order by num asc")
    public List<CityVO> findNumByCity();
}
